<% content_for :title, (all_errs ? t(".all_errors") : t(".unresolved_errors")) %>

<% content_for :head do %>
  <%= auto_discovery_link_tag :atom, problems_path(User.token_authentication_key => current_user.authentication_token, format: :atom), title: "Errbit notices at #{request.host}" %>
<% end %>

<% content_for :action_bar do %>
  <% if all_errs %>
    <%= link_to t(".hide_resolved"), problems_path(sort: params_sort, order: params_order), class: "button" %>
  <% else %>
    <%= link_to t(".show_resolved"), problems_path(all_errs: true, sort: params_sort, order: params_order), class: "button" %>
  <% end %>
<% end %>

<section>
  <%= render "problems/search", all_errs: all_errs, app_id: nil, params_sort: params_sort, params_order: params_order %>
</section>

<br>

<section>
  <div id="problem_table" class="problem_table">
    <%= render "problems/table", problems: problems %>
  </div>
</section>
